-- GENERATED SPELL FOR [Stegodon] --


function spell0_6501(pUnit, Event) --@Head Smash,n/a--
pUnit:FullCastSpellOnTarget(15652,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_6501', 2287, 1)
end

function spell1_6501(pUnit, Event) --@Rushing Charge,Self--
pUnit:FullCastSpellOnTarget(6268,pUnit)
pUnit:RegisterEvent('Sorts_6501', 3000, 1)
end

function Sorts_6501(pUnit, Event)
local choix_sorts_6501 = math.random(0, 1)
if choix_sorts_6501 == 0 then
pUnit:RegisterEvent('spell0_6501', 1, 1)
end
if choix_sorts_6501 == 1 then
pUnit:RegisterEvent('spell1_6501', 1, 1)
end
end

function mob6501_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_6501', math.random(1500, 3000), 1)
end

function mob6501_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6501_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob6501_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(6501, 1, 'mob6501_Action')
RegisterUnitEvent(6501, 2, 'mob6501_Leave')
RegisterUnitEvent(6501, 3, 'mob6501_Kill')
RegisterUnitEvent(6501, 4, 'mob6501_Die')
